package com.itheima.sh.controller;

import com.alibaba.dubbo.config.annotation.Reference;
import com.itheima.sh.api.HelloService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Description:
 * @Version: V1.0
 */
@RestController
@RequestMapping("consumer")
public class ConsumerController {

    @Reference
    HelloService helloService;

    @GetMapping("sayHello")
    public String sayHello(String username){
        return helloService.sayHello(username);
    }
}
